package com.java.zhuiyun.api.jielongidiomquestion.mapper;

import com.java.zhuiyun.api.jielongidiomquestion.entity.JieLongIdiomQuestion;
import com.java.zhuiyun.common.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * @InterfaceName Mapper
 * @Description TODO 成语接龙题库持久层
 * @Author 杨友朋
 * @Date 2023/9/13 9:00
 **/
@Mapper
public interface JieLongIdiomQuestionMapper extends BaseMapper<JieLongIdiomQuestion> {
    /**
    * @Author 杨友朋
    * @Description TODO 查询题库
    * @Date 2023/10/12 11:24
    * @Return List<JieLongIdiomQuestion>
    * @param levelId
    */
    List<JieLongIdiomQuestion> selectQuestion(Integer levelId);

    /**
    * @Author 杨友朋
    * @Description TODO 更新成语信息
    * @Date 2023/10/12 11:25
    * @Return Integer
    * @param jieLongIdiomQuestion
    */
    Integer saveWordInfo(JieLongIdiomQuestion jieLongIdiomQuestion);

    /**
    * @Author 杨友朋
    * @Description TODO 根据id查询成语信息
    * @Date 2023/10/12 11:25
    * @Return JieLongIdiomQuestion
    * @param id
    */
    JieLongIdiomQuestion selectQuestById(Integer id);

    /**
    * @Author 杨友朋
    * @Description TODO 添加成语
    * @Date 2023/10/12 11:26
    * @Return Integer
    * @param jieLongIdiomLevel
    */
    Integer insertIdiom(JieLongIdiomQuestion jieLongIdiomLevel);

    /**
    * @Author 杨友朋
    * @Description TODO 删除
    * @Date 2023/10/20 13:59
    * @Return int
    * @param id
    */
    int del(Integer id);
}
